<div class="page-title clearfix">
  <div class="title">星级规则管理</div>
  <button nz-button class="fr btn-green" [routerLink]="routerLinks.starLevelRule.add" title="添加"><i
    class="anticon anticon-plus"></i>
    添加
  </button>
</div>

<div class="page-msg m-15">
  <h3>功能描述</h3>
  <ul>
    <li *ngFor="let item of msgTip.levelRules">{{item}}</li>
  </ul>
</div>

<div class="panel">
  <nz-table #nzTable
            [nzData]="starLevelRuleList.voList"
            [nzLoading]="_loading"
            [nzFrontPagination]="false"
            [nzShowTotal]="totalRow"
            [nzPageSize]="starLevelRuleList.pageSize"
            [nzTotal]="starLevelRuleList.totalRow"
            [nzPageIndex]="starLevelRuleList.curPage"
            (nzPageIndexChange)="queryStarLevelRuleList($event)">
    <thead nz-thead>
    <ng-template #totalRow>共 {{starLevelRuleList.totalRow}} 条数据</ng-template>
    <tr>
      <th nz-th class="text-center" nzWidth="5%"><span>序号</span></th><!--序号-->
      <th nz-th class="text-center" nzWidth="20%"><span>星级名</span></th><!--星级名-->
      <th nz-th class="text-center" nzWidth="25%"><span>层级</span></th><!--层级-->
      <th nz-th class="text-center" nzWidth="20%"><span>动态奖励</span></th><!--动态奖励百分比-->
      <th nz-th class="text-center" nzWidth="20%"><span>操作</span></th><!--操作-->
    </tr>
    </thead>
    <tbody nz-tbody>
    <ng-template ngFor let-data [ngForOf]="nzTable.data" let-i="index">
      <tr nz-tbody-tr>
        <td nz-td class="text-center">{{i+1}}</td>
        <td nz-td class="text-center">{{data.starName}}</td>
        <td nz-td class="text-center">{{data.level}}</td>
        <td nz-td class="text-center">{{data.rate}}%</td>
        <td nz-td class="text-center">
          <button nz-button class="btn-blue-o mr" [routerLink]="[routerLinks.starLevelRule.modify,data.id]"
                  title="修改">
            <i class="anticon anticon-edit"></i></button>
        </td>
      </tr>
    </ng-template>
    </tbody>
  </nz-table>
</div>
